package com.wangp.mywrite.inwork.mybatis.handler;

import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/***
 * @author wangpeng
 * @since 2022-02-17  16:03
 */
@RestController
@RequiredArgsConstructor
public class FarController {

    private final FarMapper farMapper;

    @GetMapping("/mybatis/handler/test")
    public Far getFar(){
        return farMapper.selectById();
    }

    @GetMapping("/mybatis/handler/test2")
    public Integer addFar(){
        return farMapper.insertFar();
    }
}
